Japanese Patent Application Publication No. 2011-165928 discloses a semiconductor device including trench gate electrodes. In this semiconductor device, a trench extending from a front surface to a rear surface of a semiconductor substrate, and a gate insulating film covering a bottom surface and a side surface of the trench are provided. Inside the semiconductor substrate, a first conductivity type carrier-injected region making contact with the side surface of the trench at a front surface side (which, in the case of Japanese Patent Application Publication No. 2011-165928, is configured as an emitter region in IGBT. The same would be a source region for MOS), a drift region making contact with the bottom surface and side surface at a rear surface side of the trench, and a second conductivity type body region located between the first conductivity type carrier-injected region and the first conductivity type drift region and separating them are provided. In this semiconductor device, the carrier-injected region and the drift region are electrically connected by applying a potential to the trench gate electrode, the potential which inverts a part of the body region to a first conductivity type.